package com.itheima.reggie.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.itheima.reggie.entity.Category;
import com.itheima.reggie.entity.PageParam;

import java.util.List;

public interface CategoryService {

    //新增分类
    int add(Category category);

    //分页查询
    IPage<Category> findPage(PageParam pageParam);

    //删除分类
    int delete(long categoryId);

    //修改分类
    int update(Category category);

    //根据类型查询分类数据
    List<Category> findCategoryByType(Integer type);

    //根据分类id查询分类对象
    Category findById(long id);
}
